#include<bits/stdc++.h>
using namespace std;
#define N 105
typedef struct Node
{
    double m, v;
    double getRatio()
    {
        return v / m;
    }
}Node;
Node item[N];
bool cmp(Node &a, Node &b)
{
    return a.getRatio() > b.getRatio();
}
int main()
{
    int n, t;
    double sumWei = 0, sumVal = 0;
    cin>>n>>t;
    for(int i = 1; i <= n; ++i)
        cin>>item[i].m>>item[i].v;
    sort(item+1, item+n+1, cmp);    
    for(int i = 1; i <= n; ++i)
    {
        if(sumWei + item[i].m <= t)
        {
            sumVal += item[i].v;
            sumWei += item[i].m;
        }
        else
        {
            sumVal += item[i].getRatio()*(t-sumWei);
            break;
        }
    }
    cout<<fixed<<setprecision(2)<<sumVal;
    return 0;
}
